package com.ruoyi.exam.mapper;

import com.ruoyi.common.vo.PageBaseVO;
import com.ruoyi.exam.domain.ExamScores;
import com.ruoyi.exam.vo.ExamRankingReqVO;
import com.ruoyi.exam.vo.ExamScoreListReqVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface ExamScoresMapper {

    ExamScores getExamScores(@Param("examId") int examId ,@Param("uid") long uid);

    ExamScores getExamScoresForUpdate(@Param("examId") int examId ,@Param("uid") long uid);

    void addExamScores(ExamScores scores);

    void updateExamScores(ExamScores scores);

    void updateScoresRanking(List<ExamScores> list);
    void updateHandsOnScoreRanking(List<ExamScores> list);
    void updateTheoryScoreRanking(List<ExamScores> list);
    void updateMultipleTimeRanking(List<ExamScores> list);
    void updateHandsOnTimeRanking(List<ExamScores> list);
    void updateTheoryTimeRanking(List<ExamScores> list);

    List<ExamScores> pageScore(ExamRankingReqVO reqVO);

    List<ExamScores> listScore(ExamScoreListReqVO reqVO);
    int sizeListScore(ExamScoreListReqVO reqVO);

    int getPrevExamId(int examId);
}
